from Entities.Calendars.CompositeCalendar import CompositeCalendar

class UnionCalendar (CompositeCalendar):
    '''
    A union of more than two calendars
    '''
    
    def __init__ (self, children=None):
        CompositeCalendar.__init__(self, children)
           
    def isholiday (self, when):
        for calendar in self.children:
            if calendar.isholiday (when):
                return True
        return False
    
